/*
    ui 公用布局
*/

@import './public.scss';

.ui-body-min-height{
    // 主内容高度屏幕区域减去header的高度
    height: calc(100vh - 78px);
}

.ui-logo{
    height: 2rem;
    position: absolute;
    z-index: 11;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}


// 价格符号
.ui-rmb {
    &:before {
        content: '¥';
        padding-right: .2rem;
    }
}

.ui-content {
    padding: 0 .5rem;
    margin: .5rem 0; // background-color:white;
}


// 大型按钮
.ui-button-large {
    padding-right:60px;
    padding-left:60px;
}

.ui-button-text{
    color: cornflowerblue;
    border: none;
    background-color: transparent;
    box-shadow: none;
    &::after{
        background: white;
    }
}

.ui-button-tab{
    width: 150px;
    height: 45px;
    font-size: 16px;
}

.ui-button-circle{
    border: 1px solid transparent;
    border-radius: 1rem;
    height: auto;
    padding: .3rem 1.8rem;
    font-size: .8rem;
    background-color: white;
    &.orange{
        border-color: $ui-color-orange;
        color: $ui-color-orange;
    }
    &.blue{
        border-color: $ui-color-blue;
        color: $ui-color-blue;
    }
    &.red{
        border-color: $ui-color-red;
        color: $ui-color-red;
    }
}

.ui-button-radius{
    border-radius: 25px;
}

.ui-full {
    // position: fixed !important; //移动端fixed支持不好, 慎用!!!
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    z-index: 100;
}


// 分割线
.ui-dividing{
    display: block;
    position: relative;
    height: 1px;
    background: rgba(0, 0, 0, .2);
    text-align: center;
    margin: 1.5rem auto;
    >span{
        color: #999;
        background: white;
        padding: 0 1rem;
        font-size: .7rem;
        position: absolute;
        z-index: 1;
        top: 0;
        left: 50%;
        white-space: nowrap;
        transform: translate3d(-50%,-50%,0);
    }
}



.ui-border{
    border: $ui-border;
}
.ui-border-dark{
    border: 1px solid #e8e8e8;
}
.ui-border-radius-0{
    border-radius: 0;
}
.ui-border-top{
    border-top: $ui-border;
}
.ui-border-bottom{
    border-bottom: $ui-border;
}
.ui-border-left{
    border-left: $ui-border;
}
.ui-border-right{
    border-right: $ui-border;
}
.ui-circle{
    border-radius: 50%;
    border-left: none;
    border-right: none;
}

// el-form组件内容输入框尺寸
.ui-form{
    .el-select,.el-input,.el-input-number,.el-textarea{
        width: 240px;
    }
}

// 隐藏上传组件的上传按钮
.ui-no-upload{
    .el-upload{
        display: none;
    }
}

.ui-hover-shadow{
    @include hover-shadow;
}

// dialog查看大图,隐藏容器背景
.ui-img-preview{
    >.el-dialog{
        background: transparent;
        box-shadow: none;
        width: auto;
    }
}

.ui-header{
    // @include box-shadow;
    z-index: 20;
    position: relative;
    background: #fff;
    position: fixed;
    top:78px;
    left: 0;
    right: 0;
    .el-tabs__header{
        border-bottom: none;
        margin-bottom: 0;
    }
    .el-input-group__append{
        width: 90px;
    }
}

.ui-center-width{
    width: 1250px;
    margin: 0 auto;
}


@mixin tag($color){
    padding: 2px 7px;
    font-size: 14px;
    border-radius: 2px;
    color: $color;
    border: $color 1px solid;
    &.ui-tag-anti{
        // 反色
        background-color: $color;
        color: #fff;
    }
}
.ui-tag-primary{
    @include tag($ui-color-orange);
}
.ui-tag-grey{
    @include tag(#666);
}
